from rest_framework.serializers import ModelSerializer
from .models import Host


class HostModelSerializer(ModelSerializer):
    class Meta:
        model = Host
        fields = ['hostname']
        extra_kwargs = {
            'hostname': {'read_only': True}
        }
